package flexlingo.binders
{
	import flash.events.Event;
	
	import flexlingo.managers.LingoManager;
	
	import mx.containers.Accordion;
	import mx.containers.accordionClasses.AccordionHeader;
	import mx.events.ChildExistenceChangedEvent;
	import mx.core.Container;
	
	public class AccordionBinder
	{
		
		public static function bind(accordion:Accordion):void
		{
			//accordion.addEventListener(ChildExistenceChangedEvent.CHILD_ADD, AccordionBinder.childAddHandler,true); 
		}
		
		
	
		/* public static function childAddHandler(e:Event):void
		{	
				
			if( e is ChildExistenceChangedEvent)
			{
               	var event : ChildExistenceChangedEvent = e as ChildExistenceChangedEvent;
               	var header : AccordionHeader = event.relatedObject as AccordionHeader;
				LingoManager.bindProperty( header.label, header, "label");
			}
		} */
		
		
		public static function bindAccordionHeader(header:AccordionHeader):void
		{	
			LingoManager.bindProperty( header.label, header, "label");
		}
		
		

	}
}